package com.mx.utils;

import java.util.Arrays;

public class Test {

	public static void main(String[] args) {
		int [] a={8,5,6,3,1,7,2};
		int size=a.length;
		Arrays.sort(a);
		if(size%2==1){
			System.out.println(a[(a.length-1)/2]);
		}else{
			System.out.println(a[(a.length)/2]+"和"+a[(a.length)/2+1]);
		}
		
	}

}
